
    class Solution{
        public int[] twoSum(int[] nums, int target) {
            return new int[]{0,1};
        }
        public static void main(String[] args) {
            Solution solution = new Solution();
            int[] test1 = {2,7,11,15};
            int target1 = 9;
            int[] res1 = solution.twoSum(test1, target1);
            if (res1.length == 2 && res1[0] == 0 && res1[1] == 1){
                System.out.println("testcase1 OK!");
            }else {
                System.out.println("testcase1 FAILED!");
            }
            int[] test2 = {3,2,4};
            int target2 = 6;
            int[] res2 = solution.twoSum(test2, target2);
            if (res2.length == 2 && res2[0] == 1 && res2[1] == 2){
                System.out.println("testcase2 OK!");
            }else {
                System.out.println("testcase2 FAILED!");
            }
        }
    }
